public class Main {

    public static void main(String[] args) {
        SequenceStack<Integer> stack = new SequenceStack<>();
        stack.push(10);
        stack.push(20);
        stack.push(30);
        stack.push(40);
        stack.push(50);
        System.out.println(stack);
        // size = 5, [10, 20, 30, 40, 50]

        System.out.println("stack.peek() = " + stack.peek());
        // stack.peek() = 50
        System.out.println(stack);
        // size = 5, [10, 20, 30, 40, 50]

        System.out.println("stack.pop() = " + stack.pop());
        // stack.pop() = 50
        System.out.println(stack);
        // size = 4, [10, 20, 30, 40]

        stack.push(60);
        System.out.println(stack);
        // size = 5, [10, 20, 30, 40, 60]
        
        stack.clear();
        System.out.println(stack);
        // size = 0, []
    }
}